<%@ page language="java" import="java.util.*" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@include file="/context/mytags.jsp"%>
<!DOCTYPE html>
<html>
 <head>
  <title>填写设备</title>
  <t:base type="jquery,easyui,tools,DatePicker"></t:base>
   <script src="plug-in/jquery-plugs/form/jquery.form.js"></script>
   <script type="text/javascript" src="plug-in/Validform/js/Validform_v5.3.1_min_zh-cn.js"></script>
   <script type="text/javascript" src="plug-in/Validform/js/Validform_Datatype_zh-cn.js"></script>
   <script type="text/javascript" src="plug-in/Validform/js/datatype_zh-cn.js"></script>
   <link rel="stylesheet" href="plug-in/Validform/css/style.css" type="text/css">
   <link rel="stylesheet" href="plug-in/Validform/css/tablefrom.css" type="text/css">
   
 </head>
 <body>
 
  <t:formvalid formid="formobj" dialog="true" usePlugin="password" 
  			layout="table" action="" tiptype="3" >
  		<input type="hidden" id="btn_sub" class="btn_sub">
					 
		<table style="" cellpadding="0" cellspacing="1" class="formtable">
			<tbody>
				<tr>
					<td align="right">
						<label class="Validform_label">
							名称:
						</label>
					</td>
					<td class="value">
					    <input id="name" name="name" type="text" 
					     	 style="width: 150px" class="inputxt" datatype="*">
						<span class="Validform_checktip"></span>
						<label class="Validform_label" style="display: none;">名称</label>
					</td>
				</tr>
				<tr>
					<td align="right">
						<label class="Validform_label">
							单位:
						</label>
					</td>
					<td class="value">
				     	 <input id="unit" name="unit" type="text" 
					     	 style="width: 150px" class="inputxt" datatype="*" maxlength="100">
						<span class="Validform_checktip"></span>
						<label class="Validform_label" style="display: none;">单位</label>
					</td>
				</tr>
				<tr>
					<td align="right">
						<label class="Validform_label">
							数量:
						</label>
					</td>
					<td class="value">
				     	 <input id="count" name="count" type="text" 
					     	 style="width: 150px" class="inputxt" datatype="n" maxlength="100">
						<span class="Validform_checktip"></span>
						<label class="Validform_label" style="display: none;">数量</label>
					</td>
				</tr>
			</tbody>
		</table>
		</t:formvalid>
	
	<script>
		function getData(){
			var validForm = $('#formobj').Validform({tiptype:"3"}); //初始化校验form控件
			var valid = validForm.check(false);
			if(!valid) return;
			
			var obj = {};
			obj.name = $("#name").val();
			obj.model = $("#model").val();
			obj.norm = $("#norm").val();
			obj.unit = $("#unit").val();
			obj.count = $("#count").val();
			return obj;
		}
	</script>
 </body>
 